(function() {

	require(['placeholder'], function() {

		document.getElementById('subtn').onclick = function() {

			var uname = document.getElementById('uname').value;
			var psd = document.getElementById('psd').value;
			var code = document.getElementById('code').value;

			if(!uname) {
				alert('请输入用户名');
				return false;
			}
			if(!psd) {
				alert('请输入密码');
				return false;
			}
			if(!code) {
				alert('请输入验证码');
				return false;
			}

			document.login.action = '/control/login';
			document.login.submit();
		}
	});
})();